<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:p="http://primefaces.org/ui">

    <h:form id="SciftbactplanListForm">

        <p:panel header="#{myBundle.ListSciftbactplanTitle}">

            <p:dataTable id="datalist" value="#{sciftbactplanController.items}" var="item"
                         selectionMode="single" selection="#{sciftbactplanController.selected}"
                         rowKey="#{item.sciftbactplanid}"
                         paginator="true"
                         rows="5"
                         rowsPerPageTemplate="5,10,20,30"
                         >

                <p:ajax event="rowSelect"   update="createButton viewButton editButton deleteButton"/>
                <p:ajax event="rowUnselect" update="createButton viewButton editButton deleteButton"/>

                <p:column sortBy="#{item.sciftbactplanid}" filterBy="#{item.sciftbactplanid}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_sciftbactplanid}"/>
                    </f:facet>
                    <h:outputText value="#{item.sciftbactplanid}"/>
                </p:column>
                <p:column sortBy="#{item.actividad}" filterBy="#{item.actividad}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_actividad}"/>
                    </f:facet>
                    <h:outputText value="#{item.actividad}"/>
                </p:column>
                <p:column sortBy="#{item.meta}" filterBy="#{item.meta}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_meta}"/>
                    </f:facet>
                    <h:outputText value="#{item.meta}"/>
                </p:column>
                <p:column sortBy="#{item.sem1}" filterBy="#{item.sem1}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_sem1}"/>
                    </f:facet>
                    <h:outputText value="#{item.sem1}"/>
                </p:column>
                <p:column sortBy="#{item.sem2}" filterBy="#{item.sem2}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_sem2}"/>
                    </f:facet>
                    <h:outputText value="#{item.sem2}"/>
                </p:column>
                <p:column sortBy="#{item.sem3}" filterBy="#{item.sem3}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_sem3}"/>
                    </f:facet>
                    <h:outputText value="#{item.sem3}"/>
                </p:column>
                <p:column sortBy="#{item.sem4}" filterBy="#{item.sem4}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_sem4}"/>
                    </f:facet>
                    <h:outputText value="#{item.sem4}"/>
                </p:column>
                <p:column sortBy="#{item.comentario}" filterBy="#{item.comentario}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_comentario}"/>
                    </f:facet>
                    <h:outputText value="#{item.comentario}"/>
                </p:column>
                <p:column sortBy="#{item.prioridad}" filterBy="#{item.prioridad}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_prioridad}"/>
                    </f:facet>
                    <h:outputText value="#{item.prioridad}"/>
                </p:column>
                <p:column sortBy="#{item.fecharegistro}" filterBy="#{item.fecharegistro}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_fecharegistro}"/>
                    </f:facet>
                    <h:outputText value="#{item.fecharegistro}">
                        <f:convertDateTime pattern="MM/dd/yyyy HH:mm:ss" />
                    </h:outputText>
                </p:column>
                <p:column sortBy="#{item.observaciones}" filterBy="#{item.observaciones}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_observaciones}"/>
                    </f:facet>
                    <h:outputText value="#{item.observaciones}"/>
                </p:column>
                <p:column sortBy="#{item.sciftbplandocid.sciftbplandocid}" filterBy="#{item.sciftbplandocid.sciftbplandocid}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_sciftbplandocid}"/>
                    </f:facet>
                    <h:outputText value="#{item.sciftbplandocid.sciftbplandocid}"/>
                </p:column>
                <p:column sortBy="#{item.scaltblineinveid.scaltblineinveid}" filterBy="#{item.scaltblineinveid.scaltblineinveid}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_scaltblineinveid}"/>
                    </f:facet>
                    <h:outputText value="#{item.scaltblineinveid.scaltblineinveid}"/>
                </p:column>
                <p:column sortBy="#{item.pytctbactcompid.descripcion}" filterBy="#{item.pytctbactcompid.descripcion}">
                    <f:facet name="header">
                        <h:outputText value="#{myBundle.ListSciftbactplanTitle_pytctbactcompid}"/>
                    </f:facet>
                    <h:outputText value="#{item.pytctbactcompid.descripcion}"/>
                </p:column>
                <f:facet name="footer">
                    <p:commandButton id="createButton" icon="ui-icon-plus"   value="#{myBundle.Create}" actionListener="#{sciftbactplanController.prepareCreate}" update=":SciftbactplanCreateForm" oncomplete="SciftbactplanCreateDialog.show()"/>
                    <p:commandButton id="viewButton"   icon="ui-icon-search" value="#{myBundle.View}" update=":SciftbactplanViewForm" oncomplete="SciftbactplanViewDialog.show()" disabled="#{empty sciftbactplanController.selected}"/>
                    <p:commandButton id="editButton"   icon="ui-icon-pencil" value="#{myBundle.Edit}" update=":SciftbactplanEditForm" oncomplete="SciftbactplanEditDialog.show()" disabled="#{empty sciftbactplanController.selected}"/>
                    <p:commandButton id="deleteButton" icon="ui-icon-trash"  value="#{myBundle.Delete}" actionListener="#{sciftbactplanController.delete}" update=":growl,datalist" disabled="#{empty sciftbactplanController.selected}"/>
                </f:facet>

            </p:dataTable>

        </p:panel>

    </h:form>

</ui:composition>